This is a no-frills cubic-spline editor. It is designed for users of CSound exclusively, though it may very well be applicable for users of other software synthesis packages.
Its main purpose is to aid users in creating slow-moving shaping functions. As I delved into the CSound experience, I found that creating a simple smooth function for amplitude shaping was more difficult than it should be (but then again, CSound ain’t easy to begin with...). So here's Spliner to help. You can now draw out your functions and “paste” them into CSound.
I chose splines for this program (rather than line segments or exponentials) primarily because of their versatility and smoothness. Perhaps I’ll add the ability to use all three modes in the future, since the rest of the process is the same.
In the bottom of the window is a text box from which you can copy text into your CSound text editor. It is a passive element in the program, so changes you make in it will have no effect on the curve that Spliner generates. It is there as the “output” stage only. The right side of the text will clip, but you can still copy all of the text by clicking to the left of “f1” and dragging down. Then select “Copy” or “Cut” from the Edit menu.
The content of the text is straightforward. The table number and size are “fixed” at 1 and 0, ready for you to change in your text editor. The table size is set via the menu, and the function generator number is (of course) eight, for splines. Following that are number pairs (ordinate, segment length), as described in the CSound manual.
The (no-frills) TableSize menu gives you some flexibility in choosing accuracy or space efficiency. The extended guard point is omitted from Spliner; to add it, simply add one to the table size when you enter the data into CSound. The table size does not affect the shape of the curve, but it does affect the numbers in the text pane.
In the center of the window is the main editing pane. A sample spline curve of four points is shown at startup. You may move any of the points, add points, or delete points (with some constraints). The axes are unmarked, though that really doesn’t mean much. The width of the graph is just the table size, and the height will be scaled in the CSound function generator. For reference, the top of the vertical axis is +1, the bottom –1. For steep curve segments you may see some clipping of the actual curve.
The tool box in the top left allows you to select which operation to perform. The pointer with no symbol is for dragging control points. You may only drag control points between neighbors (ie, no overlap is allowed). The endpoints are fixed horizontally, but may move vertically.
Sorry folks, the cursor doesn’t change, so you have to watch the tool box.
The “point add” tool allows you to click anywhere in the pane to add another control point. The new point will be immediately absorbed into the curve. The “point delete” tool lets you remove any control point by clicking on it. The endpoints may not be deleted.
Please send bug reports (or feature-requests) to me at the address in the splash screen. I don't have any plans to implement all the ideas for beefing up this program at the moment, but if other people find it as useful as I do, I certainly will consider it. (In fact, please write just to say that you use it!)
Source code is also available upon request. Be forewarned that (1) the drawing stuff is snarfed directly from csound, (2) the bulk of the interface is created (rather clunkily) by Prototyper, and (3) it was written in a hurry.